home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus 2002 #11 / Amiga Plus CD - 2002 - No. 11.iso / Tools / MorphOS / Epic4_mos / share / epic / help / 5_programming / unshift < prev    next >
Encoding:
Text File  |  2002-10-28  |  787 b   |  21 lines

  1. Synopsis:
  2.    unshift <variable name> <word>
  3.    shift   <variable name>
  4.  
  5. Description:
  6.    UNSHIFT prepends the given word (or words) to the given variable,
  7.    padded with a single space.  The variable name itself may not contain
  8.    a leading '$'; the command uses the variable itself, not the expanded
  9.    contents.  If the variable does not exist, it is created containing
  10.    the given word(s) (just as if ASSIGN were used).
  11.  
  12. Aliases:
  13.    SHIFT is the exact opposite of UNSHIFT, in that it chops off the first
  14.    word in the variable.  If there is only one word in the variable, the
  15.    variable is deleted.  Both UNSHIFT and SHIFT are functionally equivalent
  16.    to the $unshift() and $shift() functions, respectively.
  17.  
  18. See Also:
  19.    assign(5); pop(5); push(5)
  20.  
  21.